<div th:fragment="main">
	<div class="breadcrumbs" id="breadcrumbs">
		<script type="text/javascript">
			try{ace.settings.check('breadcrumbs' , 'fixed')}catch(e){}
		</script>
		<ul class="breadcrumb">
			<li>
				<i class="icon-home home-icon"></i>
				<a th:href="@{/admin/}">Home</a>
			</li>
			<!-- <li>
				<a href="#">Other Pages</a>
			</li> -->
			<li class="active">权限管理</li>
		</ul><!-- .breadcrumb -->
		
		<div class="nav-search" id="nav-search">
			<form class="form-search">
				<span class="input-icon">
					<input type="text" placeholder="Search ..." class="nav-search-input" id="nav-search-input" autocomplete="off" />
					<i class="icon-search nav-search-icon"></i>
				</span>
			</form>
		</div><!-- #nav-search -->
	</div>
	
	<div class="page-content">
		<div class="row">
			<div class="col-xs-12">
				<!-- PAGE CONTENT BEGINS -->
				<div class="row">
					<div class="col-xs-12">
						<h3 class="header smaller lighter blue">
							<span>权限列表</span>
							<a class="btn" style="float:right;margin-top: -12px;" th:href="@{/admin/permission/add}" >
								<i class="icon-pencil align-top bigger-125"></i>权限新增
							</a>
						</h3>
						<div class="table-header" th:text="'共有'+${pu.total}+'条数据'"></div>
						<div class="table-responsive">
							<table id="sample-table-2" class="table table-striped table-bordered table-hover">
								<thead>
									<tr>
										<th class="center">
											<label>
												<input type="checkbox" class="ace" onclick="checkAll(this)" />
												<span class="lbl"></span>
											</label>
										</th>
										<th>名称</th>
										<th>Index</th>
										<th class="hidden-480">URL</th>
										<th>
											<i class="icon-time bigger-110 hidden-480"></i>
											创建时间
										</th>
										<th class="hidden-480">状态</th>
										<th>操作</th>
									</tr>
								</thead>
								<tbody>
									<tr th:each="p,stat:${pu.list}">
										<td class="center">
											<label>
												<input type="checkbox" class="ace" name="checks" />
												<span class="lbl"></span>
											</label>
										</td>
										<td>
											<a th:href="@{'/admin/permission/select/'+${p.id}}" th:text="${p.name}"></a>
										</td>
										<td th:text="${p.menuIndex}"></td>
										<td class="hidden-480" th:text="${p.url}"></td>
										<td th:text="${#dates.format(p.createTime,'yyyy-MM-dd HH:mm:ss')}"></td>
										<td class="hidden-480">
											<span class="label label-sm label-success">已创建</span>
										</td>
										<td>
											<div class="visible-md visible-lg hidden-sm hidden-xs action-buttons">
												<a class="blue" th:href="@{'/admin/permission/select/'+${p.id}}">
													<i class="icon-zoom-in bigger-130"></i>
												</a>
												<a class="green" th:href="@{'/admin/permission/upt/'+${p.id}}">
													<i class="icon-pencil bigger-130"></i>
												</a>
												<a class="red" href="javascript:void(0)">
													<i class="icon-trash bigger-130"></i>
												</a>
											</div>
											
											<div class="visible-xs visible-sm hidden-md hidden-lg">
												<div class="inline position-relative">
													<button class="btn btn-minier btn-yellow dropdown-toggle" data-toggle="dropdown">
														<i class="icon-caret-down icon-only bigger-120"></i>
													</button>
													<ul class="dropdown-menu dropdown-only-icon dropdown-yellow pull-right dropdown-caret dropdown-close">
														<li>
															<a th:href="@{'/admin/permission/select/'+${p.id}}" class="tooltip-info" data-rel="tooltip" title="View">
																<span class="blue">
																	<i class="icon-zoom-in bigger-120"></i>
																</span>
															</a>
														</li>

														<li>
															<a th:href="@{'/admin/permission/upt/'+${p.id}}" class="tooltip-success" data-rel="tooltip" title="Edit">
																<span class="green">
																	<i class="icon-edit bigger-120"></i>
																</span>
															</a>
														</li>

														<li>
															<a href="javascript:void(0)" class="tooltip-error" data-rel="tooltip" title="Delete">
																<span class="red">
																	<i class="icon-trash bigger-120"></i>
																</span>
															</a>
														</li>
													</ul>
												</div>
											</div>
											
										</td>
									</tr>
								</tbody>
							</table>
						</div>
						
						<div class="modal-footer no-margin-top">
							<ul class="pagination pull-right no-margin" id="page">
								<!-- 分页 -->
								<li th:class="${pu.pageNum==1}?'prev disabled':'prev'">
									<a th:href="${pu.pageNum==1}?'javascript:void(0)':(@{'/admin/permission/list/1'})">
										<i class="icon-double-angle-left"></i>
									</a>
								</li>
								<li th:class="${p==pu.pageNum}?'active':''" th:each="p,stat:${pc.pageList}">
									<a th:href="${p==pu.pageNum}?'javascript:void(0)':(@{'/admin/permission/list/'+${p}})" th:text="${p}"></a>
								</li>
								<li th:class="${pu.pageNum==pu.lastPage}?'next disabled':'next'">
									<a th:href="${pu.pageNum==pu.lastPage}?'javascript:void(0)':(@{'/admin/permission/list/'+${pu.lastPage}})">
										<i class="icon-double-angle-right"></i>
									</a>
								</li>
							</ul>
						</div>
						
					</div>
				</div>
				<!-- PAGE CONTENT ENDS -->
			</div><!-- /.col -->
		</div><!-- /.row -->
	</div><!-- /.page-content -->
	
</div>